package com.hopes.bizz.enforcement.hid.dto;

import com.hopes.bizz.common.core.validate.group.AddGroup;
import com.hopes.bizz.common.core.validate.group.UpdateGroup;
import com.hopes.boss.common.entity.BaseLogicEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.util.Date;
import java.util.List;

/**
 * @author daijie
 * @version 1.0
 * @date 2023/7/28 14:24
 * @Description:
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Schema(description = "隐患检查任务DTO")
public class RiskHidCheckTaskDTO extends BaseLogicEntity {

    private static final long serialVersionUID = 5096965924214640643L;

    /**
     * 计划标识
     */
    private Long planId;
    /**
     * 检查表
     */
    @NotBlank(message = "检查表为必填项", groups = {AddGroup.class, UpdateGroup.class})
    @Length(max = 500, message = "检查表最大长度为:500", groups = {AddGroup.class, UpdateGroup.class})
    private List<String> hidCheckListConfigIdList;
    /**
     * 受检对象
     */
    @NotBlank(message = "受检对象为必填项", groups = {AddGroup.class, UpdateGroup.class})
    @Length(max = 200, message = "受检对象最大长度为:200", groups = {AddGroup.class, UpdateGroup.class})
    private String checkObject;
    /**
     * 记录人
     */
    @NotNull(message = "记录人为必填项", groups = {AddGroup.class, UpdateGroup.class})
    private Long recorder;
    /**
     * 记录人身份证
     */
    @NotBlank(message = "记录人身份证为必填项", groups = {AddGroup.class, UpdateGroup.class})
    @Length(max = 200, message = "记录人身份证最大长度为:200", groups = {AddGroup.class, UpdateGroup.class})
    private String recorderIdCard;
    /**
     * 检查人
     */
    @NotBlank(message = "检查人为必填项", groups = {AddGroup.class, UpdateGroup.class})
    @Length(max = 200, message = "检查人最大长度为:200", groups = {AddGroup.class, UpdateGroup.class})
    private String checkPerson;
    /**
     * 排查单元
     */
    private List<String> riskUnitIdList;
    /**
     * 任务名称
     */
    @NotBlank(message = "任务名称为必填项", groups = {AddGroup.class, UpdateGroup.class})
    private String taskName;

    /**
     * 开始时间
     */
    @NotNull(message = "开始时间为必填项", groups = {AddGroup.class, UpdateGroup.class})
    private Date startTime;
    /**
     * 截止时间
     */
    @NotNull(message = "截止时间为必填项", groups = {AddGroup.class, UpdateGroup.class})
    private Date deadline;
}
